const express = require('express')
const router = express.Router()

router.post('/home', (req, res) => {
  res.send({
    List: [
      {name: '炫舞'},
      {name: '炫舞'},
      {name: '炫舞'},
      {name: '炫舞'},
      {name: '王者荣耀'},
      {name: '英雄联盟'},
      {name: '英雄联盟'},
      {name: '英雄联盟'},
      {name: '穿越火线'},
      {name: '战地记者'},
      {name: '问道'},
      {name: '大话西游'},
      {name: '大话西游'},
      {name: '大话西游'},
      {name: '大话西游'},
      {name: '大话西游'},
      {name: '梦幻西游'},
      {name: '炉石传说'},
      {name: '斗地主'},
      {name: '英雄世界'}
    ],
    ErrorCode: '000000',
    msg: '请求成功'
  })
})

router.post('/pullData', (req, res) => {
  res.send({
    List: Array.from({ length: 20 }, () => Math.floor(Math.random() * 10)),
    ErrorCode: '000000',
    msg: '请求成功'
  })
})

module.exports = router

